﻿@using KMF.Utility
@using KMF.WebUI.CustomHelpers
@model List<KMF.Common.ProductMenuHomeDto>
@if (Model.Any())
{
    <ul class="list-promotion-cate">
        @foreach (var item in Model)
        {
            var pDetailLink = Url.Action("Index", "ProductDetail", new { productId = item.Id, productName = StringUtil.RemoveSpecialCharactersVn(item.Name) });
            <li>
                <a href="@pDetailLink" class="prom-item">
                    <img src="@item.ImagePath.ImagePathThumb(60, 60)" width="60" height="60" alt="@item.Name" />
                    <div class="prom-head">
                        <span class="prom-title">@item.Name</span><br />
                        <span class="prom-ncc">@item.ProviderName</span>
                    </div>
                    @if (item.PromotionPrice > 0)
                    {
                        <div class="root-prom-price">
                            @item.Price.ToString("##,###")<sup>đ</sup>
                        </div>
                        <div class="prom-price">
                            @item.PromotionPrice.ToString("##,###")<sup>đ</sup>
                        </div>
                    }
                    else
                    {
                        <div class="prom-price">
                            @item.Price.ToString("##,###")<sup>đ</sup>
                        </div>
                    }
                </a>
            </li>
        }
    </ul>
}
